package com.terrier.ui.events
{
    import flash.events.Event;

    /**
     * Range事件.
     * @author Jarvis.weng
     */
    public class WxRangeEvent extends Event
    {
        static public const VALUE_CHANGE:String = "valueChange";

        private var _oldValue:Number;

        private var _newValue:Number;

        public function WxRangeEvent(type:String, oldValue:Number, newValue:Number, bubbles:Boolean = false, cancelable:Boolean = false)
        {
            super(type, bubbles, cancelable);

            _oldValue = oldValue;
            _newValue = newValue;
        }

        public function get newValue():Number
        {
            return _newValue;
        }

        public function get oldValue():Number
        {
            return _oldValue;
        }

        override public function clone():Event
        {
            return new WxRangeEvent(type, oldValue, newValue, bubbles, cancelable);
        }
    }
}
